package com.ruoyi.oa.domain.bo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.core.validate.AddGroup;
import com.ruoyi.common.core.validate.EditGroup;
import lombok.Data;
import lombok.EqualsAndHashCode;
import javax.validation.constraints.*;

import java.util.Date;
import java.util.List;

import com.ruoyi.common.core.domain.BaseEntity;
import org.springframework.format.annotation.DateTimeFormat;

/**
 * 比价信息业务对象 oa_purchase_parity
 *
 * @author ruoyi
 * @date 2023-04-03
 */

@Data
@EqualsAndHashCode(callSuper = true)
public class OaPurchaseParityBo extends BaseEntity {

    /**
     * 主键
     */
    @NotBlank(message = "主键不能为空", groups = { EditGroup.class })
    private String id;

    /**
     * 部门id
     */
    private Long deptId;

    /**
     * 用户id
     */
    private Long userId;
//    /**
//     * 采购类型（0：非行政类采购；1：行政类采购）
//     */
//    @NotBlank(message = "采购类型（0：非行政类采购；1：行政类采购）不能为空", groups = { AddGroup.class, EditGroup.class })
//    private String purchaseType;

    /**
     * 项目名称
     */
    @NotBlank(message = "项目名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String projectName;

    /**
     * 物品名称
     */
//    @NotBlank(message = "物品名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String objectName;

    /**
     * 规格型号
     */
//    @NotBlank(message = "规格型号不能为空", groups = { AddGroup.class, EditGroup.class })
    private String specificationModel;

    /**
     * 数量
     */
//    @NotBlank(message = "数量不能为空", groups = { AddGroup.class, EditGroup.class })
    private String number;

    /**
     * 开始时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd")
    private Date startDate;

    /**
     * 结束时间
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd")
    private Date endDate;


    /**
     * 比价供应商
     */
    private String parityList;

    /**
     * 比价推荐说明
     */
    @NotBlank(message = "比价推荐说明不能为空", groups = { AddGroup.class, EditGroup.class })
    private String recommendedInstructions;

    /**
     * 提交时间范围
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    private List<Date> submitTimeList;

    /**
     * 提交时间 终
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date submitStartDate;

    /**
     * 提交时间起
     */
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm")
    private Date submitEndDate;


    /**
     * 流程状态
     */
    private String status;

    /**
     * oss集合
     */
    private String attachment;


    /**
     * 上次流程
     */
    private String lastWorkflow;

    @NotBlank(message = "采购主体不能为空", groups = { AddGroup.class, EditGroup.class })
    private String payUnit;

    @NotBlank(message = "采购事项名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String itemName;

    @NotNull(message = "付款日期不能为空", groups = { AddGroup.class, EditGroup.class })
    @DateTimeFormat(pattern = "yyyy-MM-dd")
    @JsonFormat(locale="zh", timezone="GMT+8", pattern="yyyy-MM-dd")
    private Date designDate;


    /**
     * 创建
     */
    private String createUser;
}
